<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateUsersTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('users', function (Blueprint $table) {
            $table->increments('id');
            $table->string('name')->default('')->comment('用户名');
            $table->string('icon')->default('https://ss0.baidu.com/6ONWsjip0QIZ8tyhnq/it/u=2284174980,259589504&fm=5')->comment('用户头像');
            $table->string('email')->unique()->default('')->comment('邮箱');
            $table->string('phone')->unique()->default('')->comment('手机');
            $table->string('password')->default('')->comment('密码');
            $table->string('sex')->default('')->comment('性别');
            $table->string('birthday')->default('')->comment('生日');
            $table->string('work')->default('')->comment('职业');
            $table->string('introduction')->default('')->comment('介绍');
            $table->rememberToken();
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('users');
    }
}
